/**
 * 显示加载框
 */

export const ml_showLoading = () =>{
  return new Promise((resolve)=>{
    wx.showLoading({
      title: '加载中...',
      success: resolve
    })
  })
}

/**
 * 隐藏加载框
 */
export const ml_hideLoading = () =>{
  return new Promise((resolve)=>{
    wx.hideLoading({
      success: resolve
    })
  })
}

/**
 * 成功提示框
 */
export const ml_showToast = (title) =>{
  return new Promise((resolve)=>{
    wx.showToast({
      title,
      success:resolve
    })
  })
}

/**
 * 提示框
 */
export const ml_Toast = (title) =>{
  return new Promise((resolve)=>{
    wx.showToast({
      title,
      icon:'none',
      success:resolve
    })
  })
}

/**
 * 提示框
 */
export const ml_showModal = (title,content) =>{
  return new Promise((resolve)=>{
    wx.showModal({
      title,
      content,
      success:resolve
    })
  })
}
